/**
 * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package com.bar.carta.model;

import java.io.Serializable;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

/**
 * This class is used by SOAP remote services, specifically {@link com.bar.carta.service.http.TipoServiceSoap}.
 *
 * @author    pgonzalm
 * @see       com.bar.carta.service.http.TipoServiceSoap
 * @generated
 */
public class TipoSoap implements Serializable {
	public static TipoSoap toSoapModel(Tipo model) {
		TipoSoap soapModel = new TipoSoap();

		soapModel.setTipoId(model.getTipoId());
		soapModel.setCreateDate(model.getCreateDate());
		soapModel.setActivo(model.getActivo());

		return soapModel;
	}

	public static TipoSoap[] toSoapModels(Tipo[] models) {
		TipoSoap[] soapModels = new TipoSoap[models.length];

		for (int i = 0; i < models.length; i++) {
			soapModels[i] = toSoapModel(models[i]);
		}

		return soapModels;
	}

	public static TipoSoap[][] toSoapModels(Tipo[][] models) {
		TipoSoap[][] soapModels = null;

		if (models.length > 0) {
			soapModels = new TipoSoap[models.length][models[0].length];
		}
		else {
			soapModels = new TipoSoap[0][0];
		}

		for (int i = 0; i < models.length; i++) {
			soapModels[i] = toSoapModels(models[i]);
		}

		return soapModels;
	}

	public static TipoSoap[] toSoapModels(List<Tipo> models) {
		List<TipoSoap> soapModels = new ArrayList<TipoSoap>(models.size());

		for (Tipo model : models) {
			soapModels.add(toSoapModel(model));
		}

		return soapModels.toArray(new TipoSoap[soapModels.size()]);
	}

	public TipoSoap() {
	}

	public long getPrimaryKey() {
		return _tipoId;
	}

	public void setPrimaryKey(long pk) {
		setTipoId(pk);
	}

	public long getTipoId() {
		return _tipoId;
	}

	public void setTipoId(long tipoId) {
		_tipoId = tipoId;
	}

	public Date getCreateDate() {
		return _createDate;
	}

	public void setCreateDate(Date createDate) {
		_createDate = createDate;
	}

	public boolean getActivo() {
		return _activo;
	}

	public boolean isActivo() {
		return _activo;
	}

	public void setActivo(boolean activo) {
		_activo = activo;
	}

	private long _tipoId;
	private Date _createDate;
	private boolean _activo;
}